package cn.com.digitalnet.ad.aop;

import org.aspectj.lang.ProceedingJoinPoint;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import cn.com.digitalnet.ad.util.Holder;
import cn.com.digitalnet.ad.util.PropertiesHolder;

/**
 * 方便页面显示配置文件中的信息
 * @author qidafang
 */
@Component//方便页面显示配置文件中的信息
public class HolderAspect {
	
	@Autowired PropertiesHolder holder;
	
	public Object doAround(ProceedingJoinPoint p) throws Throwable{
		
		Holder.request.get().setAttribute("holder", holder);
		
		return p.proceed();
	}
}
